#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# Copyright (c) 2022, Jonas Kazem Andersen
#
# This file is part of the modm project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
# -----------------------------------------------------------------------------

def init(module):
    module.name = ":driver:ads101x"
    module.description = """\
# ADS101x ADC

The ADS1013/ADS1014/ADS1015 are ultra-low power, high precision analog-digital converters.
"""

def prepare(module, options):
    module.depends(
        ":architecture:i2c.device",
        ":architecture:register")
    return True

def build(env):
    env.outbasepath = "modm/src/modm/driver/adc"
    env.copy("ads101x.hpp")
    env.copy("ads101x_impl.hpp")
